package com.order.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.order.pojo.OrderItem;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;

@Data
@TableName("order")
public class Order {
    @TableId(type = IdType.ASSIGN_UUID)
    private String orderId;
    private String userId;
    private BigDecimal orderAmount;
    private Integer orderStatus;
    private LocalDateTime createTime;
    private LocalDateTime updateTime;

    // 关联订单项，一对多关系
    private List<OrderItem> orderItems;
}